//
//  EFAAppModel.h
//  efairy
//
//  Created by XiangDongMBP on 2017/8/12.
//  Copyright © 2017年 East. All rights reserved.
//

#import <Foundation/Foundation.h>
#import <YYModel.h>
#import <UIKit/UIKit.h>



#pragma mark - 项目管理
@interface EFAPjtAddViewCfg : NSObject
@property (nonatomic, copy)   NSString *key;                ///< key
@property (nonatomic, copy)   NSString *keyDes;             ///< key中文描述
@property (nonatomic, copy)   NSString *value;              ///< value
@property (nonatomic, assign) UIKeyboardType keyboardType;  ///< 键盘类型
@property (nonatomic, assign) BOOL isInput;                 ///< 是否可以用输入
@property (nonatomic, assign) BOOL isTextField;             ///< 是TextField或者TextView
@property (nonatomic, assign) NSInteger valueMinLen;        ///< 最小长度
@property (nonatomic, assign) NSInteger valueMaxLen;        ///< 最大长度
@property (nonatomic, copy)   NSString *prompt;             ///< 提示信息
@property (nonatomic, assign) BOOL enabled;                 ///< 是否可以更改数值
@property (nonatomic, assign) BOOL scanEnabled;             ///< 是否可以扫一扫


@end


@interface EFAPjtListItem : NSObject<NSCoding>
@property (nonatomic, assign) NSInteger efairyproject_id;            ///< 项目编号
@property (nonatomic, copy)   NSString *efairyproject_name;          ///< 项目名称
@property (nonatomic, assign) NSInteger efairyproject_creator_id;    ///< 项目创建人编号
@property (nonatomic, assign) NSInteger efairyproject_user_id;       ///< 项目负责人编号
@property (nonatomic, copy)   NSString *efairyproject_user_name;     ///< 项目负责人名称
@property (nonatomic, copy)   NSString *efairyproject_user_phonenumber;///< 项目负责人手机号
@property (nonatomic, copy)   NSString *efairyproject_description;   ///< 项目描述
@property (nonatomic, copy)   NSString *efairyproject_address;       ///< 项目地址
@property (nonatomic, assign) NSInteger efairyproject_device_online_number; //!< 设备在线数
@property (nonatomic, assign) NSInteger efairyproject_total_devices; ///< 设备总数
@property (nonatomic, assign) NSInteger efairyproject_total_users;   ///< 项目用户总数
@property (nonatomic, assign) NSInteger efairyproject_total_gms;     ///< 项目管理员总数
@property (nonatomic, assign) double efairyproject_location_lat;     ///< 纬度(小数点6位)
@property (nonatomic, assign) double efairyproject_location_lng;     ///< 经度(小数点6位)
//0-离线 1-火警 2-预警 3-故障 4-启动 5-屏蔽 6-正常 只要有异常，均为1，否则为0
@property (nonatomic, assign) BOOL efairyproject_state;              ///< 项目状态，只要有异常，均为1，否则为0 
@property (nonatomic, assign) NSInteger efairyproject_fee_type;      ///< 费用类型
//0-离线 1-火警 2-预警 3-故障 4-启动 5-屏蔽 6-正常，优先级:离线 报警  预警  故障 启动 屏蔽 正常
@property (nonatomic, assign) NSInteger efairyproject_alarm_id;      ///< 项目状态，0-离线 1-火警 2-预警 3-故障 4-启动 5-屏蔽 6-正常
//一下是1.4新增的
@property (nonatomic, assign) BOOL isSelected;  ///< 用户是否选中
@property (nonatomic, assign) NSInteger total_rows; // 总设备数
@property (nonatomic, assign) NSInteger efairyuserhasproject_project_id;//27,
@property (nonatomic, assign) NSInteger efairyproject_trouble_number;// 故障数
@property (nonatomic, assign) NSInteger efairyproject_detail_state;//6,
@property (nonatomic, assign) NSInteger efairyproject_fire_number;//0,// 报警数
@property (nonatomic, copy)   NSString *efairyproject_uuid;//15027868840011,
@property (nonatomic, assign) NSInteger efairyproject_ew_number;//0,// 预警数

@end



@interface EFAProjectModel : NSObject<NSCoding>
@property (nonatomic, assign) NSInteger total_rows;
@property (nonatomic, strong) NSMutableArray<EFAPjtListItem *> *project_list;

@property (nonatomic, readonly) NSArray<EFAPjtListItem *> *selPjtArray; ///< 选中的项目列表
@property (nonatomic, readonly) BOOL hasSelPjt; ///< 用户已经选中项目
@property (nonatomic, readonly) BOOL totalLoad; ///< 是否全部加载
@property (nonatomic, readonly) BOOL totalZero; ///< 是否为0
- (void)addMoreWithData:(EFAProjectModel *)temp;
@end


#pragma mark - 项目管理详情
@interface EFAPjtDetUserItem : NSObject
@property (nonatomic, assign) NSInteger efairyuser_id;          //!< ID
@property (nonatomic, copy)   NSString *efairyuser_nickname;    //!< 昵称
@property (nonatomic, copy)   NSString *efairyuser_phonenumber; //!< 手机号
@end
//@interface EFAPjtDetDeviceItem : NSObject
//@property (nonatomic, assign) NSInteger efairydevice_id;
//@property (nonatomic, copy)   NSString *efairydevice_name;
//@end
@class EFADeviceListItem;
@interface EFAPjtDetailModel : NSObject
@property (nonatomic, strong) EFAPjtListItem *project_info;
@property (nonatomic, strong) NSMutableArray<EFAPjtDetUserItem *> *gm_list;
@property (nonatomic, strong) NSMutableArray<EFAPjtDetUserItem *> *user_list;
@property (nonatomic, strong) NSMutableArray<EFADeviceListItem *> *device_list;

// 自定义数据
@property (nonatomic, assign) BOOL gm_list_unfolder;      //!< 折叠标志位
@property (nonatomic, assign) BOOL user_list_unfolder;    //!< 折叠标志位
@property (nonatomic, assign) BOOL device_list_unfolder;  //!< 折叠标志位

// 自定义函数
@property (nonatomic, readonly) BOOL isGMTotalLoad;
@property (nonatomic, readonly) BOOL isUserTotalLoad;
@property (nonatomic, readonly) BOOL isDeviceTotalLoad;
@property (nonatomic, readonly) BOOL isGMTotalZero;
@property (nonatomic, readonly) BOOL isUserTotalZero;
@property (nonatomic, readonly) BOOL isDeviceTotalZero;
- (void)addMoreGMWithDictionary:(NSDictionary *)dic;        //!< 增加管理员
- (void)addMoreDeviceWithDictionary:(NSDictionary *)dic;    //!< 增加设备
- (void)addMoreUserWithDictionary:(NSDictionary *)dic;      //!< 增加用户
- (void)gmListWithDictionary:(NSDictionary *)dic isAddMore:(BOOL)addMore;       //!< 管理员列表
- (void)userListWithDictionary:(NSDictionary *)dic isAddMore:(BOOL)addMore;     //!< 用户列表
- (void)deviceListWithDictionary:(NSDictionary *)dic isAddMore:(BOOL)addMore;   //!< 设备列表
- (void)removeUserAtIndex:(NSInteger)index; //!< 移除用户
- (void)removeGMAtIndex:(NSInteger)index;   //!< 移除管理员
@end


#pragma mark - 项目管理详情-用户列表
@interface EFAPjtUserModel : NSObject
@property (nonatomic, assign) NSInteger total_rows;
@property (nonatomic, strong) NSMutableArray<EFAPjtDetUserItem *> *user_list;

@property (nonatomic, readonly) BOOL totalLoad;
- (void)addMoreWithData:(EFAPjtUserModel *)temp;
@end

#pragma mark - 项目管理详情-选择ICCID
@interface EFAPjtIotItem : NSObject
@property (nonatomic, assign) NSInteger efairyiotcard_id;        //!< 编号
@property (nonatomic, copy)   NSString *efairyiotcard_number;    //!< 卡号
@property (nonatomic, assign) BOOL efairyiotcard_is_used;        ///< 是否已使用
@end

@interface EFAPjtIotModel : NSObject
@property (nonatomic, assign) NSInteger total_rows;
@property (nonatomic, strong) NSMutableArray<EFAPjtIotItem *> *efairyiotcard_list;

@property (nonatomic, readonly) BOOL totalLoad;
@property (nonatomic, readonly) BOOL totalZero;
- (void)addMoreWithData:(EFAPjtIotModel *)temp;
@end

#pragma mark - 报表
@interface EFARptOviAnaItem : NSObject
@property (nonatomic, assign) NSInteger device_type;    //!< 设备类型，具体类型需要参考《网络传输协议》
@property (nonatomic, assign) NSInteger install_number; //!< 安装数量
@property (nonatomic, assign) NSInteger alarm_number;   //!< 报警设备数量
@property (nonatomic, assign) NSInteger alarm_scale;    //!< 报警比例，百分比
@property (nonatomic, assign) NSInteger alarm_times;    //!< 报警次数

// 自定义函数
@property (nonatomic, readonly) NSString *deviceTypeDes;//!< 设备类型描述
@end
@interface EFARptOverView : NSObject
@property (nonatomic, assign) NSInteger safely_points;
@property (nonatomic, strong) NSArray<EFARptOviAnaItem *> *overview_analyze_list;
// 自定义函数
@property (nonatomic, readonly) NSInteger device_total_number;
@property (nonatomic, readonly) NSInteger device_alarm_number;
@property (nonatomic, readonly) NSInteger device_normal_number;
@end
@interface EFARptScaleMapItem : NSObject
@property (nonatomic, assign) NSInteger pt;             //!< 参量类型，具体参考《网络传输协议-表7》
@property (nonatomic, assign) NSInteger alarm_times;    //!< 报警次数
// 自定义函数
@property (nonatomic, readonly) NSString *ptDes;        //!< 对应的pt描述
@end
@interface EFARptAlarmScaleItem : NSObject
@property (nonatomic, assign) NSInteger device_type;    //!< 设备类型，具体类型需要参考《网络传输协议》
@property (nonatomic, strong) NSArray<EFARptScaleMapItem *> *scale_map_list;
// 自定义函数
@property (nonatomic, readonly) NSString *deviceTypeDes;    //!< 设备类型描述
@property (nonatomic, readonly) NSArray<NSDictionary *> *pieData;//!< 画饼形图需要的数据
@end
@interface EFARptAlarmDataItem : NSObject
@property (nonatomic, copy)   NSString *efairydevicefiredata_time;       //!< 报警时间
@property (nonatomic, assign) NSInteger efairydevicefiredata_state;      //!< 通道状态
@property (nonatomic, assign) NSInteger efairydevicefiredata_parameter;  //!< 参量类型
@property (nonatomic, assign) NSInteger efairydevicefiredata_rtv;        //!< 实时值
@property (nonatomic, assign) NSInteger efairydevicefiredata_thv;        //!< 阀值
@property (nonatomic, assign) NSInteger efairydevicefiredata_cid;        //!< 报警通道号
@end
@interface EFARptModel : NSObject
@property (nonatomic, strong) EFARptOverView *overview;
@property (nonatomic, strong) NSArray<EFARptAlarmScaleItem *> *alarm_scale_map_list;
@property (nonatomic, strong) NSArray<EFARptAlarmDataItem *> *alarm_data_list;
@property (nonatomic,   copy) NSString *start_time; //!< 起始时间
@property (nonatomic,   copy) NSString *end_time;   //!< 结束时间

// 自定义变量
@property (nonatomic, strong) NSCalendar *calendar; //!< 日历
// 自定义函数
@property (nonatomic, readonly) NSArray<EFARptScaleMapItem *> *alarm_total;  //!< 统计报告文字内容
@property (nonatomic, readonly) NSString *reportDescribe;                    //!< 报告文字内容
- (NSArray<NSDictionary *> *)sortAlarmDataWithType:(NSInteger)type; //!< 0-日报 1-周报 2-月报 3-季报 4-年报
@end



#pragma mark - 公告
// 发布公告的item
@interface EFANotPubItem : NSObject
@property (nonatomic, strong) UIImage *img;         //!< 缩略图
@property (nonatomic, strong) NSData *originalData; //!< 原图数据
@property (nonatomic, copy)   NSString *content;    //!< 图片描述
@property (nonatomic, copy)   NSString *image_url;  //!< 上传之后得到的图片连接

- (instancetype)initWithImage:(UIImage *)img originalData:(NSData *)data;
@end

@interface EFANotInfo : NSObject
@property (nonatomic, copy)   NSString *efairyannouncement_title;      ///< 公告标题
@property (nonatomic, copy)   NSString *efairyannouncement_content;    //!< 公告详情
@property (nonatomic, strong) NSMutableArray<EFANotPubItem *> *efairyannouncement_image_list;///< 图片列表
@end

@interface EFANoticePubModel : NSObject
@property (nonatomic, assign) NSInteger visibility_mode;    ///< 可视模式：1-所有项目可见，2-部分项目可见，3-部分项目不可见
@property (nonatomic, strong) NSMutableArray<EFAPjtListItem *> *project_list;///< 项目列表
@property (nonatomic, strong) EFANotInfo *efairyannouncement_info;           ///< 公告信息

@property (nonatomic, readonly) BOOL isImgUpload;               ///< 图片是否已经上传
@property (nonatomic, readonly) NSArray<UIImage *> *imgArray;   ///< 缩略图数组
@property (nonatomic, readonly) NSArray<NSNumber *>*pjtIdList;  ///< 项目ID列表
@property (nonatomic, readonly) NSArray<NSString *> *urlArray;  ///< 上传之后的图片连接
- (void)addPublishItemsWithImgArray:(NSArray<UIImage *> *)imgArray originalDataArray:(NSArray<NSData *> *)dataArray;
- (void)removePublishItemAtIndex:(NSInteger)index;
- (void)updateImgUrlWithArray:(NSArray<NSString *> *)array;
@end


@interface EFANotImgItem : NSObject
@property (nonatomic, assign) NSInteger efairyannounceimage_id;
@property (nonatomic,   copy) NSString *efairyannouncementimage_imgurl;
@end
@interface EFANotListItem : NSObject
@property (nonatomic, assign) NSInteger efairyannouncement_id;      ///< 公告编号
@property (nonatomic,   copy) NSString *efairyannouncement_title;   ///< 公告标题
@property (nonatomic,   copy) NSString *efairyannouncement_content; ///< 公告内容
@property (nonatomic,   copy) NSString *efairyannouncement_add_time;///< 公告的发送时间
@property (nonatomic, assign) NSInteger efairyannouncement_publisher_id;///< 公告发送者编号
@property (nonatomic,   copy) NSString *efairyannouncement_publisher_nickname;///< 公告发送者昵称
@property (nonatomic, assign) BOOL efairyuserhasannouncement_is_read;   ///< 消息是否已读，0-否 1-是
@property (nonatomic, strong) NSArray<EFANotImgItem *> *efairyannouncement_image_list; ///< 图片列表
@end
@interface EFANoticeListModel : NSObject
@property (nonatomic, assign) NSInteger total_rows;
@property (nonatomic, strong) NSMutableArray<EFANotListItem *> *announcement_list;

@property (nonatomic, readonly) BOOL totalLoad;
@property (nonatomic, readonly) BOOL totalZero;
- (void)addMoreWithData:(EFANoticeListModel *)temp;
- (void)removeNotListItem:(EFANotListItem *)item;
@end


#pragma mark - 维护记录
@interface EFAMtcPubModel : NSObject
@property (nonatomic, assign) NSInteger efairymtrecord_device_id;   ///< 设备编号
@property (nonatomic, copy)   NSString *efairymtrecord_title;       ///< 维修标题
@property (nonatomic, assign) NSInteger efairymtrecord_mt_type_id;  ///< 维护类型编号
@property (nonatomic, assign) NSInteger efairymtreord_mt_handle_id;         ///< 维护结果类型编号
@property (nonatomic, assign) NSInteger efairymtrecord_is_insite_handle;    ///< 是否现场处理
@property (nonatomic, copy)   NSString *efairymtrecord_content;             //!< 维修内容
@property (nonatomic, strong) NSMutableArray<EFANotPubItem *> *image_list;  ///< 图片列表

///< 自定义变量
@property (nonatomic, assign) NSInteger imgMaxCnt;              ///< 最多可以选择照片的数量
///< 自定义函数
@property (nonatomic, readonly) NSString *mt_type_name;         ///< 维护类型名称
@property (nonatomic, readonly) NSString *mt_handle_title;      ///< 维护结果标题
@property (nonatomic, readonly) NSString *mt_handle_name;       ///< 维护结果类型名称
@property (nonatomic, readonly) BOOL isEmpty;                   ///< 检查是否有用户输入
@property (nonatomic, readonly) BOOL isImgUpload;               ///< 图片是否已经上传
@property (nonatomic, readonly) NSArray<UIImage *> *imgArray;   ///< 缩略图数组
@property (nonatomic, readonly) NSArray<NSString *> *urlArray;  ///< 上传之后的图片连接
- (void)addPublishItemsWithImgArray:(NSArray<UIImage *> *)imgArray originalDataArray:(NSArray<NSData *> *)dataArray;
- (void)removePublishItemAtIndex:(NSInteger)index;
- (void)updateImgUrlWithArray:(NSArray<NSString *> *)array;
@end

@interface EFAMtcListItem : NSObject
@property (nonatomic, assign) NSInteger efairymtrecord_id;          ///< 记录编号
@property (nonatomic, assign) NSInteger efairymtrecord_device_id;   ///< 设备编号
@property (nonatomic,   copy) NSString *efairydevice_name;          ///< 设备名称
@property (nonatomic, assign) NSInteger efairymtrecord_user_id;     ///< 维护者编号
@property (nonatomic,   copy) NSString *efairyuser_nickname;        ///< 维修者名字
@property (nonatomic,   copy) NSString *efairyuser_headimg_url;     ///< 维修者头像
@property (nonatomic, assign) NSInteger efairymtrecord_mt_type_id;  ///< 维护类型编号
@property (nonatomic, assign) NSInteger efairymtreord_mt_handle_id; ///< 维护结果类型编号
@property (nonatomic, assign) BOOL efairymtrecord_is_insite_handle; ///< 是否现场处理
@property (nonatomic,   copy) NSString *efairymtrecord_content;     ///< 维修内容
@property (nonatomic,   copy) NSString *efairymtrecord_time;        ///< 记录时间
@property (nonatomic, strong) NSArray<NSString *> *efairymtrecord_imgurl_list; ///< 图片列表

///< 自定义函数
@property (nonatomic, readonly) NSString *mt_type_name;         ///< 维护类型名称
@property (nonatomic, readonly) NSString *mt_handle_title;      ///< 维护结果标题
@property (nonatomic, readonly) NSString *mt_handle_name;       ///< 维护结果类型名称
@end
@interface EFAMtcRcdListModel : NSObject
@property (nonatomic, assign) NSInteger total_rows;
@property (nonatomic, strong) NSMutableArray<EFAMtcListItem *> *mtrecord_list;

@property (nonatomic, readonly) BOOL totalLoad;
@property (nonatomic, readonly) BOOL totalZero;
- (void)addMoreWithData:(EFAMtcRcdListModel *)temp;
- (void)removeNotListItem:(EFAMtcListItem *)item;
@end


extern NSString *const EFAMtcTypeId;     //!< 维护类型ID
extern NSString *const EFAMtcTypeName;   //!< 维护类型Name
extern NSString *const EFAMtcResultId;   //!< 是否完成处理类型ID
extern NSString *const EFAMtcResultName; //!< 是否完成处理类型Name
@interface EFAMtcTypeModel : NSObject
@property (nonatomic, strong) NSArray *typeArray;

@property (nonatomic, readonly) NSArray<NSString *> *mtcTypeNameArray;
+ (instancetype)sharedInstance;
- (NSArray *)resultTypeWithMtcTypeId:(NSInteger)mtcTypeId;
- (NSString *)mtcTypeNameWithMtcTypeId:(NSInteger)mtcTypeId;
- (NSString *)mtcResultTitleWithMtcTypeId:(NSInteger)mtcTypeId;
- (NSString *)mtcResultNameWithMtcResultId:(NSInteger)mtcResultId;
@end


#pragma mark - 报警处理
@interface EFAAlarmPubModel : NSObject
@property (nonatomic, assign) NSInteger efairydevice_id;                    ///< 设备编号
@property (nonatomic, strong) NSArray<NSNumber *> *efairydevicemsg_id_list; ///< 消息ID
@property (nonatomic, assign) NSInteger efairyalarmrecord_alarm_id;         ///< 维护类型编号
@property (nonatomic, assign) NSInteger efairyalarmrecord_is_handle;        ///< 维护结果类型编号
@property (nonatomic, assign) NSInteger efairyalarmrecord_is_insite_handle; ///< 是否现场处理
@property (nonatomic, copy)   NSString *efairyalarmrecord_content;          //!< 维修内容
@property (nonatomic, strong) NSMutableArray<EFANotPubItem *> *image_list;  ///< 图片列表

///< 自定义变量
@property (nonatomic, assign) NSInteger imgMaxCnt;              ///< 最多可以选择照片的数量
///< 自定义函数
@property (nonatomic, readonly) BOOL isEmpty;                   ///< 检查是否有用户输入
@property (nonatomic, readonly) BOOL isImgUpload;               ///< 图片是否已经上传
@property (nonatomic, readonly) NSArray<UIImage *> *imgArray;   ///< 缩略图数组
@property (nonatomic, readonly) NSArray<NSString *> *urlArray;  ///< 上传之后的图片连接
- (void)addPublishItemsWithImgArray:(NSArray<UIImage *> *)imgArray originalDataArray:(NSArray<NSData *> *)dataArray;
- (void)removePublishItemAtIndex:(NSInteger)index;
- (void)updateImgUrlWithArray:(NSArray<NSString *> *)array;
@end

@interface EFAAlarmListItem : NSObject
@property (nonatomic, assign) NSInteger efairyalarmrecord_id;       ///< 记录编号
@property (nonatomic, assign) NSInteger efairyalarmrecord_device_id;///< 设备ID
@property (nonatomic,   copy) NSString *efairydevice_name;          ///< 设备名称
@property (nonatomic, assign) NSInteger efairyalarmrecord_user_id;  ///< 维护者编号
@property (nonatomic,   copy) NSString *efairyuser_nickname;        ///< 维修者名字
@property (nonatomic,   copy) NSString *efairyuser_headimg_url;     ///< 维修者头像
@property (nonatomic, assign) NSInteger efairyalarmrecord_alarm_id; ///< 报警类型
@property (nonatomic, assign) NSInteger efairyalarmrecord_is_handle;    ///< 故障是否排除，0-否 1-是
@property (nonatomic, assign) BOOL efairyalarmrecord_is_insite_handle;  ///< 是否现场处理，0-否 1-是
@property (nonatomic,   copy) NSString *efairyalarmrecord_content;      ///< 维修内容
@property (nonatomic,   copy) NSString *efairyalarmrecord_add_time;     ///< 记录时间
@property (nonatomic, strong) NSArray<NSString *> *efairyalarmrecord_imgurl_list; ///< 图片列表
@end
@interface EFAAlarmRcdListModel : NSObject
@property (nonatomic, assign) NSInteger total_rows;
@property (nonatomic, strong) NSMutableArray<EFAAlarmListItem *> *alarmrecord_list;

@property (nonatomic, readonly) BOOL totalLoad;
@property (nonatomic, readonly) BOOL totalZero;
- (instancetype)initWithAlarmListItem:(EFAAlarmListItem *)item;
- (void)addMoreWithData:(EFAAlarmRcdListModel *)temp;
- (void)removeNotListItem:(EFAAlarmListItem *)item;
@end

@interface EFAAlarmDevListItem : NSObject
@property (nonatomic, assign) NSInteger efairydevice_id;   ///< 设备编号
@property (nonatomic,   copy) NSString *efairydevice_name; ///< 设备名称
@property (nonatomic, assign) NSInteger unhandle_number;   ///< 未处理数量
@end
@interface EFAAlarmDevListModel : NSObject
@property (nonatomic, assign) NSInteger total_rows;
@property (nonatomic, strong) NSMutableArray<EFAAlarmDevListItem *> *unhandle_device_list;

@property (nonatomic, readonly) BOOL totalLoad;
@property (nonatomic, readonly) BOOL totalZero;
- (void)addMoreWithData:(EFAAlarmDevListModel *)temp;
@end


#pragma mark - 隐患曝光
@interface EFADangerPubModel : NSObject
@property (nonatomic, assign) NSInteger efairyhiddendanger_project_id;      ///< 项目ID
@property (nonatomic, copy)   NSString *efairyhiddendanger_project_name;    ///< 项目名称
@property (nonatomic, copy)   NSString *efairyhiddendanger_title;           //!< 隐患标题
@property (nonatomic, copy)   NSString *efairyhiddendanger_content;         //!< 隐患内容
@property (nonatomic, assign) NSInteger efairyhiddendanger_is_fixed;        ///< 是否已经处理，0-否 1-是
@property (nonatomic, strong) NSMutableArray<EFANotPubItem *> *image_list;  ///< 图片列表

///< 自定义变量
@property (nonatomic, assign) NSInteger imgMaxCnt;              ///< 最多可以选择照片的数量
///< 自定义函数
@property (nonatomic, readonly) BOOL isEmpty;                   ///< 检查是否有用户输入
@property (nonatomic, readonly) BOOL isImgUpload;               ///< 图片是否已经上传
@property (nonatomic, readonly) NSArray<UIImage *> *imgArray;   ///< 缩略图数组
@property (nonatomic, readonly) NSArray<NSString *> *urlArray;  ///< 上传之后的图片连接
- (void)addPublishItemsWithImgArray:(NSArray<UIImage *> *)imgArray originalDataArray:(NSArray<NSData *> *)dataArray;
- (void)removePublishItemAtIndex:(NSInteger)index;
- (void)updateImgUrlWithArray:(NSArray<NSString *> *)array;
@end

@interface EFADangerListItem: NSObject
@property (nonatomic, assign) NSInteger efairyhiddendanger_id;      ///< 隐患编号
@property (nonatomic,   copy) NSString *efairyhiddendanger_title;   ///< 隐患标题
@property (nonatomic,   copy) NSString *efairyhiddendanger_content; ///< 隐患内容
@property (nonatomic, assign) NSInteger efairyhiddendanger_user_id; ///< 隐患曝光人员
@property (nonatomic,   copy) NSString *efairyhiddendanger_add_time;///< 隐患曝光时间
@property (nonatomic,   copy) NSString *efairyuser_headimg_url;     ///< 头像
@property (nonatomic,   copy) NSString *efairyuser_headimg_url_fixed_user;///< 排除者的头像
@property (nonatomic,   copy) NSString *efairyuser_nickname;        ///< 昵称
@property (nonatomic,   copy) NSString *efairyuser_nickname_fixed_user;   ///< 排除者的昵称
@property (nonatomic, assign) NSInteger efairyhiddendanger_is_fixed;     ///< 是否已经处理，0-否 1-是
@property (nonatomic, assign) NSInteger efairyhiddendanger_project_id;      ///< 所属项目
@property (nonatomic, copy)   NSString *efairyproject_name;         ///< 项目名称
@property (nonatomic, assign) NSInteger efairyhiddendanger_fixed_user_id;   ///< 隐患排查人员
@property (nonatomic,   copy) NSString *efairyhiddendanger_fixed_time;      ///< 隐患排查时间
@property (nonatomic, strong) NSArray<NSString *> *efairyhiddendanger_imgurl_list; ///< 图片列表
@end

@interface EFADangerListModel : NSObject
@property (nonatomic, assign) NSInteger total_rows;
@property (nonatomic, strong) NSMutableArray<EFADangerListItem *> *hiddendanger_list;

@property (nonatomic, readonly) BOOL totalLoad;
@property (nonatomic, readonly) BOOL totalZero;
- (instancetype)initWithDangerListItem:(EFADangerListItem *)item;
- (void)addMoreWithData:(EFADangerListModel *)temp;
@end


#pragma mark - 用户反馈
@interface EFAFeedbackModel : NSObject
@property (nonatomic, copy)   NSString *efairyfeedback_content;             ///< 反馈内容
@property (nonatomic, strong) NSMutableArray<EFANotPubItem *> *image_list;  ///< 图片列表

///< 自定义变量
@property (nonatomic, assign) NSInteger imgMaxCnt;              ///< 最多可以选择照片的数量
///< 自定义函数
@property (nonatomic, readonly) BOOL isEmpty;                   ///< 检查是否有用户输入
@property (nonatomic, readonly) BOOL isImgUpload;               ///< 图片是否已经上传
@property (nonatomic, readonly) NSArray<UIImage *> *imgArray;   ///< 缩略图数组
@property (nonatomic, readonly) NSArray<NSString *> *urlArray;  ///< 上传之后的图片连接
- (void)addPublishItemsWithImgArray:(NSArray<UIImage *> *)imgArray originalDataArray:(NSArray<NSData *> *)dataArray;
- (void)removePublishItemAtIndex:(NSInteger)index;
- (void)updateImgUrlWithArray:(NSArray<NSString *> *)array;
@end

#pragma mark - 暂时无用
@interface EFAAppModel : NSObject
@end
